package com.loan.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.loan.group.LoanStatusGroup;
import lombok.*;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

@Data
@TableName("emp")
public class Emp implements Serializable {
    @TableId(value = "id",type = IdType.AUTO)
    @NotNull(message = "当前员工的id不能为空",groups = {LoanStatusGroup.class})
    private Integer id;

    @NotBlank(message = "当前员工的账号不能为空",groups = {LoanStatusGroup.class})
    private String account;

    private String password;

    private String status;

    private String name;

    private String gender;

    @TableField("role_id")
    private Integer roleid;

}